# Maintainer: Leonardo Arena <rnalrd@alpinelinux.org>
pkgname=vanessa_socket
pkgver=0.0.13
pkgrel=3
pkgdesc="User space TCP/IP pipe"
url="https://projects.horms.net/projects/vanessa/"
arch="all"
license="LGPL-2.0-or-later"
depends_dev="popt-dev vanessa_logger-dev"
makedepends="$depends_dev"
subpackages="$pkgname-dev $pkgname-doc"
source="https://projects.horms.net/projects/vanessa/download/vanessa_socket/$pkgver/vanessa_socket-$pkgver.tar.bz2"

prepare() {
	default_prepare
	update_config_sub
}

build() {
	export LDFLAGS="$LDFLAGS -lvanessa_logger"
	./configure \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr \
		--sysconfdir=/etc \
		--mandir=/usr/share/man \
		--infodir=/usr/share/info
	make
}

check() {
	make check
}

package() {
	make DESTDIR="$pkgdir" install
}

sha512sums="c5f39cdf796f71f32cf0a4944f48871346d10529768777caec530451d96662fe35a8bc3d01bb4e6eeddfeb09cd8629212963bdf3999c896b52772e7d8e758b27  vanessa_socket-0.0.13.tar.bz2"
